<template>
  <div class="back">
    <div class="linear">
      <span class="small">工单编号：</span>
      <span class="gdh">{{childData.fgdno}}</span>
      <img src="../assets/module2.png" style="width: 60px; height: 30px; float: left"
           @click="gotoEdit(childData.fid.toString())"/>
    </div>

    <div class="linear">
      <span class="small">签发单位：</span>
      <span class="middle">{{childData.dept_name}}</span>
      <span class="small">签发人：</span>
      <span class="middle">{{childData.fryxm}}</span>
    </div>

    <div class="linear">
      <span class="small">设备：</span>
      <span class="middle">{{childData.fsbname}}</span>
      <span class="small">机构：</span>
      <span class="middle">{{childData.fsbjgname}}</span>
    </div>

    <div class="linear">
      <span class="small">子机构：</span>
      <span class="middle">{{childData.fsbzjgname}}</span>
      <span class="small">部件：</span>
      <span class="middle">{{childData.fsbbjname}}</span>
    </div>

    <div class="linear">
      <span class="small">问题描述：</span>
      <span class="big">{{childData.fnote}}</span>
    </div>
  </div>

</template>

<script>
  export default {
    name: "BillItem",
    props: ['childData'],
    data() {
      return {
        // fid: childData.fid
      }
    },
    methods: {
      showToast() {
        this.$toast('')
      },
      gotoEdit(id) {
        this.$router.push({name: 'EditBillPage', params: {'fid': id}});
      }

    }
  }
</script>

<style scoped>
  .back {
    border: 2px;
    border-style: solid;
    border-color: #EEEEEE;
    width: 96%;
    height: auto;
    background: white;
    border-radius: 5px;
    margin: 2%;
    vertical-align: center;
  }

  .linear {
    padding: 5px;
    height: 25px;
    width: 100%;
  }

  .linear .gdh {
    float: left;
    width: 50%;
    margin: 5px;
    height: auto;
    text-align: left;
    font-weight: bold;
    color: red;
    font-family: 黑体;
  }

  .linear .small {
    float: left;
    width: 21%;
    margin: 5px;
    height: auto;
    text-align: left;
  }

  .linear .middle {
    float: left;
    width: 20%;
    margin: 5px;
    height: 15px;
    text-align: left;
    font-family: 黑体;
  }

  .linear .big {
    float: left;
    width: 70%;
    margin: 5px;
    height: 15px;
    text-align: left;
  }

</style>
